#define  _CRT_SECURE_NO_WARNINGS 1
#include "Listh.h"

test1() {
	LTNode* phead = LTInit();
	LTPushBack(phead,1);
	LTPushBack(phead, 2);
	LTPushBack(phead, 3);
	LTPushBack(phead, 4);
	LTPrint(phead);
	LTPopBack(phead);
	LTPrint(phead);
}

test2() {
	LTNode* phead = LTInit();
	LTPushFront(phead, 1);
	LTPushFront(phead, 2);
	LTPushFront(phead, 3);
	LTPushFront(phead, 4);
	LTPrint(phead);
	LTPopFront(phead);
	LTPrint(phead);
}

test3() {
	LTNode* phead = LTInit();
	LTPushFront(phead, 1);
	LTPushFront(phead, 2);
	LTPushFront(phead, 3);
	LTPushFront(phead, 4);

	LTNode* pos = LTFind(phead,3);
	if (pos) {
		pos->data *= 10;
	}
	LTPrint(phead);
	LTInsert(pos,20);
	LTPrint(phead);
	LTErase(pos);
	LTPrint(phead);
	size_t a = LTSize(phead);
	LTDestroy(phead);
}
int main() {
	//test1();
	//test2();
	test3();
	return 0;
}



